package com.chey.controller;

import com.chey.domain.ResponseData;
import org.apache.ibatis.annotations.Param;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author JanYao
 * @version 0.1
 */
@RestController
public class RegisterControlller {
    @Autowired
    private com.chey.service.VerifyService verifyService;
    @GetMapping("/reg/verify")
    public ResponseData verify(@Param("code") String code){
        String verifyCode = verifyService.verifyCode(code);
        ResponseData data = new ResponseData();
        data.setCode(200);
        data.setData(verifyCode);
        return data;
    }
}
